{% extends 'base.html' %}

{% block content %}
<h5>Edit item</h5>
<!--<form method="post">
    Name <input type="text" name="title" autocomplete="off" required value="{{ movie.title }}">
    Year <input type="text" name="year" autocomplete="off" required value="{{ movie.year }}">
    <input class="btn btn-success" type="submit" name="submit" value="Update">
</form>-->
<form method="post" class="form-inline">
    <div class="form-group">
        <label class="col-form-label mr-2">电影名</label>
        <input class="form-control mr-lg-2" type="text" name="title" autocomplete="off" required value="{{ movie.title }}">
    </div>
    <div class="form-group">
        <label class="col-form-label mr-2">上线日期</label>
    	<input class="form-control mr-lg-4" type="text" name="year" id="movedatepicker" placeholder="请选择日期" required value="{{ movie.year }}">
    </div>
  <div class="form-group">
       <button type="submit" class="btn btn-success" name="submit" value="Update">更新</button>
  </div>
</form>

<script type="text/javascript">
 $("#movedatepicker").datepicker({
        //language: 'zh-CN', //语言
        format: 'yyyy',
        language: "zh-CN",
        autoclose:true,
        startView: 2,
        minViewMode: 2,
        maxViewMode: 2,
        clearBtn: true
    });
</script>


{% endblock %}